﻿using System;
using System.Linq;
using System.Windows.Controls;
using System.Windows;
using LSA.Framework;
using System.Windows.Media;

namespace Visuals
{
    public class Interface
    {
        //public LsaSpace lsaSpace = new LsaSpace();
        //public Label BuildLabel(string content)
        //{
        //    var label = new Label()
        //    {
        //        Content = content,
        //        Height = 22,
        //        Width = 100,
        //        Background = Brushes.Transparent,
        //        Padding = new Thickness(4),
        //        VerticalAlignment = VerticalAlignment.Center,
        //        VerticalContentAlignment = VerticalAlignment.Center,
        //        HorizontalAlignment = HorizontalAlignment.Center,
        //        HorizontalContentAlignment = HorizontalAlignment.Center
        //    };
        //    return label;
        //}

        //public ToolTip BuildTooltip(string word)
        //{
        //    int wordID = lsaSpace.GetWordId(word);
        //    StackPanel stackPanel = new StackPanel();
        //    TextBlock textBlockWordID = new TextBlock();
        //    TextBlock textBlockWords = new TextBlock() { Text = "\nDocuments with the word:" };
        //    TextBlock textRelation = new TextBlock();
        //    ListBox listBoxDocuments = new ListBox();
        //    textBlockWordID.Text = String.Format("Word ID: {0} ", wordID);
        //    textRelation.Text = String.Format("\nRelation with the main word: Find the main word");

        //    for (int i = 0; i < lsaSpace.DocumentsWithWord(wordID).Count; i++)
        //    {
        //        listBoxDocuments.Items.Add(lsaSpace.FileNames[lsaSpace.DocumentsWithWord(wordID)[i]].Split('\\').Last());
        //    }
        //    stackPanel.Children.Add(textBlockWordID);
        //    stackPanel.Children.Add(textBlockWords);
        //    stackPanel.Children.Add(listBoxDocuments);

        //    ToolTip toolTip = new ToolTip()
        //    {
        //        Content = stackPanel,
        //        Background = Brushes.Honeydew,
        //        Height = 200,
        //        Width = 200,
        //        VerticalAlignment = VerticalAlignment.Center,
        //        HorizontalAlignment = HorizontalAlignment.Center
        //    };
        //    return toolTip;
        //}
    }
}
